#include <stdio.h>
#include <stdlib.h>
#include <string.h>

int main() {
    // 模拟从文件读取的一行数据
    char line[] = "1 4 \"2025-09-12 11:00\" \"2025-09-12 12:00\"\n";
    int seat_id, user_id;
    char start_time[20], end_time[20];
    
    // 使用正确的格式字符串解析带引号的时间
    int result = sscanf(line, "%d %d \"%19[^"]\" \"%19[^"]\"", &seat_id, &user_id, start_time, end_time);
    
    printf("解析结果: seat_id=%d, user_id=%d, start_time=%s, end_time=%s\n", seat_id, user_id, start_time, end_time);
    printf("成功解析字段数: %d\n", result);
    
    return 0;
}